#ifndef LOGIN_H
#define LOGIN_H

#include <QDialog>
#include <QMessageBox>
#include <QTcpSocket>

#include "mainwindow.h"

namespace Ui {
class login;
}

class login : public QDialog {
    Q_OBJECT

   public:
    explicit login(QWidget *parent = 0);
    ~login();

   private slots:
    void on_buttonRegister_clicked();

    void on_buttonLogin_clicked();

    void handConnect();
    void handRead();
   signals:
    sendData(QString);

   private:
    Ui::login *ui;
    QTcpSocket *sock;
    QString Name;
    //弹出一个提示框
    void msgbox(QString msg);
};

#endif  // LOGIN_H
